﻿@inherits LayoutComponentBase
@inject NavigationManager NavigationManager
@inject IFreeSql FreeSql

<CascadingValue Value="Setting" Name="@nameof(SettingDto)">

    <MApp Class="slide-in-left">
        <div class="@Class" @ontouchstart="TouchStart" @ontouchend="TouchEnd" @onmousedown="Mousedown" @onmouseup="Mouseup" style="height: 100%">
            @Body
        </div>

        <MFooter App Style="padding:0;">
            <MTabs Centered
                   BackgroundColor="indigo"
                   ShowArrows="false"
                   Style="@("background-color:"+Color+" !important")"
                   Value="selectModel.Key"
                   Dark>
                @foreach (var i in AppBars)
                {
                    <MTab Value="i.Key" OnClick="()=>GoHref(i)">
                        @if (!string.IsNullOrEmpty(i.Icon))
                        {
                            <MIcon Dark>@i.Icon</MIcon>
                        }
                        @i.Name
                    </MTab>
                }
            </MTabs>
        </MFooter>
    </MApp>
</CascadingValue>